
<!DOCTYPE html>
<!--

    Copyright (c) 2017, 2019 Oracle and/or its affiliates. All rights reserved.

    This program and the accompanying materials are made available under the
    terms of the Eclipse Public License v. 2.0, which is available at
    http://www.eclipse.org/legal/epl-2.0.

    This Source Code may also be made available under the following Secondary
    Licenses when the conditions for such availability set forth in the
    Eclipse Public License v. 2.0 are satisfied: GNU General Public License,
    version 2 with the GNU Classpath Exception, which is available at
    https://www.gnu.org/software/classpath/license.html.

    SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0

-->
<!-- Portions Copyright [2019] [Payara Foundation and/or its affiliates] -->
<html lang="en">
  <head>
    <meta charset="utf-8"/>
    <title>export-http-lb-config</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <link href="css/style.css" rel="stylesheet">
    <script src="https://use.fontawesome.com/96c4d89611.js"></script>
  </head>
  <body>
<table id="doc-title" cellspacing="0" cellpadding="0">
  <tr>
  <td align="left" valign="top">
  <b>export-http-lb-config</b><br />
  </td>
  </tr>
</table>
<hr />

<table width="90%" id="top-nav" cellspacing="0" cellpadding="0">
	<colgroup>
		<col width="12%"/>
		<col width="12%"/>
		<col width="*"/>
	</colgroup>
	<tr>
		<td align="left">
		<a href="export.html">
			<span class="vector-font"><i class="fa fa-arrow-circle-left" aria-hidden="true"></i></span>
			<span style="position:relative;top:-2px;">Previous</span>
		</a>
		</td>

		<td align="left">
		<a href="export-sync-bundle.html">
			<span class=" vector-font"><i class="fa fa-arrow-circle-right vector-font" aria-hidden="true"></i></span>
			<span style="position:relative;top:-2px;">Next</span>
		</a>
		</td>

		<td align="right">
		<a href="toc.html">
			<span class=" vector-font"><i class="fa fa-list vector-font" aria-hidden="true"></i></span>
			<span style="position:relative;top:-2px;">Contents</span>
		</a>
		</td>
	</tr>
</table>


<div id="preamble">
<div class="sectionbody">
<div class="paragraph">
<p><a id="export-http-lb-config-1"></a><a id="GSRFM00133"></a><a id="export-http-lb-config"></a></p>
</div>
</div>
</div>
<div class="sect1">
<h2 id="_export_http_lb_config">export-http-lb-config</h2>
<div class="sectionbody">
<div class="paragraph">
<p>exports the load balancer configuration or load balancer to a file</p>
</div>
<div id="sthref1161" class="paragraph">
<p>Synopsis</p>
</div>
<div class="listingblock">
<div class="content">
<pre class="prettyprint highlight"><code class="language-oac_no_warn" data-lang="oac_no_warn">asadmin [asadmin-options] export-http-lb-config [--help]
--config config_name | --lbname load_balancer_name
[--target target] [--retrievefile=false] [file_name]</code></pre>
</div>
</div>
<div id="sthref1162" class="paragraph">
<p>Description</p>
</div>
<div class="paragraph">
<p>The <code>export-http-lb-config</code> subcommand exports a load balancer
configuration or load balancer into a file that the load balancer
plug-in can use. The default file name is <code>loadbalancer.xml</code>, but you
can specify a different name. Once exported, you manually copy the
exported file to the load balancer plug-in location before configuration
changes are applied. The <code>--target</code> option makes it possible to generate
a <code>loadbalancer.xml</code> for clusters or standalone instances without having
to manually create <code>lb-config</code> or <code>load-balancer</code> elements in the
target&#8217;s <code>domain.xml</code>.</p>
</div>
<div class="paragraph">
<p>To apply changes to the load balancer without manually copying the
configuration file, configure the load balancer to automatically apply
changes with <code>create-http-lb</code>. If you use the <code>create-http-lb</code>
subcommand, you do not need to use <code>export-http-lb-config</code>.</p>
</div>
<div class="admonitionblock note">
<table>
<tr>
<td class="icon">
<div class="title">Note</div>
</td>
<td class="content">
<div class="paragraph">
<p>This subcommand is only applicable to Oracle Payara Server. This
subcommand is not applicable to Payara Server Open Source Edition.</p>
</div>
</td>
</tr>
</table>
</div>
<div id="sthref1163" class="paragraph">
<p>Options</p>
</div>
<div class="dlist">
<dl>
<dt class="hdlist1">asadmin-options</dt>
<dd>
<p>Options for the <code>asadmin</code> utility. For information about these
options, see the <a href="asadmin.html#asadmin-1m"><code>asadmin</code>(1M)</a> help page.</p>
</dd>
<dt class="hdlist1"><code>--help</code></dt>
<dt class="hdlist1"><code>-?</code></dt>
<dd>
<p>Displays the help text for the subcommand.</p>
</dd>
<dt class="hdlist1"><code>--config</code></dt>
<dd>
<p>Specifies which load balancer configuration to export.<br>
Specify either a load balancer configuration or a load balancer.
Specifying both results in an error.</p>
</dd>
<dt class="hdlist1"><code>--lbname</code></dt>
<dd>
<p>Specifies the load balancer to export.<br>
Specify either a load balancer configuration or a load balancer.
Specifying both results in an error.</p>
</dd>
<dt class="hdlist1"><code>--retrievefile</code></dt>
<dd>
<p>If set to <code>true</code>, retrieves the <code>loadbalancer.xml</code> file from the
remote machine. The default is <code>false</code>.</p>
</dd>
<dt class="hdlist1"><code>--target</code></dt>
<dd>
<p>Specifies the target to which the load balancer configuration will be
exported. If a target is not specified, the load balancer
configuration is exported to the location specified with file_name.</p>
</dd>
</dl>
</div>
<div id="sthref1164" class="paragraph">
<p>Operands</p>
</div>
<div class="dlist">
<dl>
<dt class="hdlist1">file_name</dt>
<dd>
<p>Specifies the file name and location of the exported configuration.<br></p>
<div class="ulist">
<ul>
<li>
<p>If you specify a directory (relative or absolute) but not a file
name, the file named `loadbalancer.xml.`load_balancer_config_name is
created in the specified directory. On Microsoft Windows systems the
path must be in quotes.</p>
</li>
<li>
<p>If you specify a file name in a relative or absolute path, the file
is created with the name you specify in the directory you specify.</p>
</li>
<li>
<p>If you specify a file name but do not specify a directory, the file
is created with that name in the current working directory.</p>
</li>
<li>
<p>If you do not specify this operand, the default value is a file
named <code>loadbalancer.xml.`load_balancer_config_name created in the
domain-dir</code>/generated` directory.</p>
</li>
</ul>
</div>
</dd>
<dt class="hdlist1">target</dt>
<dd>
<p>Specifies the target to which the configuration will be exported.<br>
Valid values are:<br></p>
<div class="ulist">
<ul>
<li>
<p>cluster_name- Specifies a cluster and its server instances.</p>
</li>
<li>
<p>stand-alone_instance_name- Specifies a specific server instance.</p>
</li>
</ul>
</div>
</dd>
</dl>
</div>
<div id="sthref1165" class="paragraph">
<p>Examples</p>
</div>
<div class="paragraph">
<p><a id="GSRFM612"></a><a id="sthref1166"></a></p>
</div>
<div class="paragraph">
<p>Example 1   Exporting a Load Balancer Configuration on UNIX</p>
</div>
<div class="paragraph">
<p>The following example exports a load balancing configuration named
<code>mycluster-http-lb-config</code> to a file named <code>loadbalancer.xml</code> in the
<code>/Sun/AppServer</code> directory .</p>
</div>
<div class="listingblock">
<div class="content">
<pre class="prettyprint highlight"><code class="language-oac_no_warn" data-lang="oac_no_warn">asadmin&gt; export-http-lb-config --config mycluster-http-lb-config /Sun/AppServer/loadbalancer.xml
Command export-http-lb-config executed successfully.</code></pre>
</div>
</div>
<div class="paragraph">
<p><a id="GSRFM613"></a><a id="sthref1167"></a></p>
</div>
<div class="paragraph">
<p>Example 2   Exporting a Load Balancer Configuration on Windows</p>
</div>
<div class="paragraph">
<p>The following example exports a load balancing configuration named
<code>mycluster-http-lb-config</code> to a file named <code>loadbalancer.xml</code> in the
<code>C:\Sun\AppServer</code> directory on a Microsoft Windows system.</p>
</div>
<div class="listingblock">
<div class="content">
<pre class="prettyprint highlight"><code class="language-oac_no_warn" data-lang="oac_no_warn">asadmin&gt; export-http-lb-config --config mycluster-http-lb-config "C:\Sun\AppServer\loadbalancer.xml"
Command export-http-lb-config executed successfully.</code></pre>
</div>
</div>
<div id="sthref1168" class="paragraph">
<p>Exit Status</p>
</div>
<div class="dlist">
<dl>
<dt class="hdlist1">0</dt>
<dd>
<p>subcommand executed successfully</p>
</dd>
<dt class="hdlist1">1</dt>
<dd>
<p>error in executing the subcommand</p>
</dd>
</dl>
</div>
<div id="sthref1169" class="paragraph">
<p>See Also</p>
</div>
<div class="paragraph">
<p><a href="asadmin.html#asadmin-1m"><code>asadmin</code>(1M)</a></p>
</div>
<div class="paragraph">
<p><a href="create-http-lb.html#create-http-lb-1"><code>create-http-lb</code>(1)</a>,
<a href="create-http-lb-config.html#create-http-lb-config-1"><code>create-http-lb-config</code>(1)</a>,
<a href="list-http-lb-configs.html#list-http-lb-configs-1"><code>list-http-lb-configs</code>(1)</a></p>
</div>
</div>
</div>

<hr />

<table width="90%" id="bottom-nav" cellspacing="0" cellpadding="0">
	<colgroup>
		<col width="12%"/>
		<col width="12%"/>
		<col width="*"/>
	</colgroup>
	<tr>		
		<td align="left">
		<a href="export.html">
			<span class=" vector-font"><i class="fa fa-arrow-circle-left" aria-hidden="true"></i></span>
			<span style="position:relative;top:-2px;">Previous</span>
		</a>
		</td>

		<td align="left">
		<a href="export-sync-bundle.html">
			<span class="vector-font"><i class="fa fa-arrow-circle-right vector-font" aria-hidden="true"></i></span>
			<span style="position:relative;top:-2px;">Next</span>
		</a>
		</td>

		<td align="right">
		<a href="toc.html">
			<span class="vector-font"><i class="fa fa-list vector-font" aria-hidden="true"></i></span>
			<span style="position:relative;top:-2px;">Contents</span>
		</a>
		</td>
	</tr>
</table>

<span id="copyright">
        <img src="/resource/reference/img/eclipse_foundation_logo_tiny.png" height="20px" alt="Eclipse Foundation Logo" align="top"/>&nbsp;            
        <span >Copyright&nbsp;&copy;&nbsp;2019,&nbsp;Oracle&nbsp;and/or&nbsp;its&nbsp;affiliates.&nbsp;All&nbsp;rights&nbsp;reserved.</span>
</span>

</body>
</html>
